
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <link rel="shortcut icon" type="image/ico" href="http://www.datatables.net/favicon.ico">
    <meta name="viewport" content="initial-scale=1.0, maximum-scale=2.0">

    <title>CTKTTH</title>
    <link rel="stylesheet" type="text/css" href="{$baseUrl}/styles/dm.css">
	<link rel="stylesheet" href="{$baseUrl}/lib/pkp/styles/pkp.css" type="text/css" />
	<link rel="stylesheet" href="{$baseUrl}/lib/pkp/styles/common.css" type="text/css" />
	<link rel="stylesheet" href="{$baseUrl}/styles/common.css" type="text/css" />

    <link rel="stylesheet" type="text/css" class="init">
    <script type="text/javascript" src="{$baseUrl}/classes/acct/js/CNKTTHList.js"></script>
 </head>

<div id = "ttNam" style="display:none">{$xNam}</div>
<body class="dt-example">
<br>

<div id = "headerTitle2" style=" 
width: 100%;
height: 30px;
line-height: 30px;
color: red;
background-color: aliceblue; 
vertical-align: middle;
text-align: center;
font-weight: bold; ">CÔNG TY DƯỢC III</div>
{include file="acct/acctNavbar.tpl"}
{include file="acct/breadcrumbs.tpl"}

<form method="post" action="{url Nam= $xNam } ">
<table width = "70%" align = "left" >
<tr rowspan = "2">
<td width = "80%" align = "center" >
<hr size="2" noshade style="color:#000000"  />
T&#7915; ngày: 
{html_select_date prefix="dateExpire1" all_extra="class=\"selectMenu\""  day_extra= 1 start_year="-5" end_year="+5" time="$Date1"}
&#272;&#7871;n ngày: 
{html_select_date prefix="dateExpire2" all_extra="class=\"selectMenu\""  day_extra= 1 start_year="-5" end_year="+5" time="$Date2"}
</td>

</tr>
<tr height = "12px">
</tr>
<tr rowspan = "2">
<td width = "80%" align = "center" >
	<select name="searchField" size="1" class="selectMenu">
		{html_options options=$fieldOptions selected=$searchField}
	</select>

	<select name="searchMatch" size="1" class="selectMenu">
		<option value="contains"{if $searchMatch == 'contains'} selected="selected"{/if}>C&#243; ch&#7913;a</option>
		<option value="is"{if $searchMatch == 'is'} selected="selected"{/if}>L&#224;</option>
		<option value="startsWith"{if $searchMatch == 'startsWith'} selected="selected"{/if}>B&#7855;t &#273;&#7847;u l&#224; </option>
	</select>

	<input type="text" size="10" name="search" class="textField" value="{$search|escape}" />&nbsp;
	<input type="submit" value="Tìm - Xem " class="button" />
	<input id="cancel" type="button" onclick="Ret('{$urlRet}');" value="Trở về " class="button" />

	<hr size="2" noshade style="color:#000000"  />
		
</td>

</tr>


<tr>

</tr>
</table>
{assign var="socot" value="9"}
{assign var="socot1" value="8"}

<br>
<table width = "70%" align = "left">
 {if $ctkts->wasEmpty()}
<tr>
	<td colspan="{$socot}" class="nodata">Khong co du lieu</td>
</tr>
<tr>
	<td colspan="{$socot}" class="endseparator">&nbsp;</td>
</tr>

{else}
<tr>
	<td colspan="{$socot1}" align="left">{page_info iterator=$ctkts}</td>
	<td align="right">{page_links anchor="ctkts" name="ctkts" iterator=$ctkts searchField=$searchField searchMatch=$searchMatch search=$search ngay1 = $Date1 ngay2 = $Date2 }</td>
</tr>

{/if}
</table>


</form>           
        <table id="customers"  cellspacing="0" width="100%">

            <thead>
            <tr>
                <th  > NGÀY </th>
                <th  > SỐ CT </th>
                <th  > DIỄN GIẢI </th>
                <th  > TK Nợ </th>
		<th  > Chi tiết TK Nợ </th>
                <th  > TK Có </th>
		<th  > Chi tiết TK Có </th>
		<th  > Số tiền </th>
		<th  > Tác vụ </th>
            </tr>
            </thead>

            <tfoot>
            <tr>

            </tr>
            </tfoot>

            <tbody>
    	   

	    {iterate from=ctkts item=ctkt name=ctkts}
                <tr>
                    <td >
			{$ctkt->getngct()|date_format:"%d/%m/%Y"|escape}
                    </td>
                    <td>
                            {$ctkt->getsoct()|escape}
                    </td>
                     <td id="noidung">
                        {$ctkt->getdiengiai()|escape}
                    </td>
                    <td>
                        {$ctkt->gettkno()|escape}
                    </td>
                    <td>
                        {$ctkt->getmacttkno()|escape}
                    </td>
                    <td>
                        {$ctkt->gettkco()|escape}
                    </td>

                    <td>
                        {$ctkt->getmacttkco()|escape}
                    </td>

                    <td id="sotien">
                            {$ctkt->getsotienvn()|number_format:0:".":"."}
                    </td>
			<td >
			<a  id = '{$ctkt->getidphieu()}' class="actiondelrow" href="javascript:void(0);" onclick="editCT('{$ctkt->getidphieu()}', '{$url}');">S&#7917;a </a>  &nbsp &nbsp
			<a  id = '{$ctkt->getidphieu()}' class="actiondelrow" href="javascript:void(0);" onclick="deleCT('{$journalid}','{$xNam}', '{$ctkt->getsoct()}', '{$ctkt->getidphieu()}', '{$urlDel}', '{$urlRFR}');">X&#243;a </a>  
		    </td>		</tr>
            {/iterate}

	  </tbody>
        </table>
        <br>
</body>
</html>